package apiroutes

import (
	"dataaysn/internal/service"

	"github.com/gin-gonic/gin"
)

func RegisterDoctorRoutes(r *gin.Engine, doctorService *service.HisDoctorService) {
	doctorGroup := r.Group("/api/doctors")
	{
		doctorGroup.POST("", doctorService.CreateDoctor)
		doctorGroup.GET("", doctorService.ListDoctorsByDepartment)
		doctorGroup.GET("/:id", doctorService.GetDoctorByID)
		doctorGroup.GET("/hospital/:hospitalCode", doctorService.ListDoctorsByHospital)
		doctorGroup.PUT("/:id", doctorService.UpdateDoctor)
		doctorGroup.DELETE("/:id", doctorService.DeleteDoctor)
	}
}
